import { defineStore } from 'pinia'

import $axios from '../tools/axios'

export const useTrainlineStore = defineStore('trainline', {
  state: () => {
    return {
      tableData: []
    }
  },
  actions: {
    async loadwithschedule() {
      const path = '/t/q/lws'
      const { data: res } = await $axios.get(path)
      if (res.code === 200) {
        this.tableData = res.data
      }
    }
  }
})
